import Vue from 'vue'
import VueRouter from 'vue-router'

Vue.use(VueRouter)
import Government from "@/views/government/index";
const routes = [
  {
    path: '/login',
    component: () => import('@/views/login'),
    hidden: true
  },

  {
    path: '',
    component: Government,
    redirect: 'home',
    children: [
      {
        path: 'home',
        component: () => import('@/views/government/home'),
        name: 'Home',
        meta: { title: '首页', icon: 'dashboard', affix: true }
      },
      {
        path: 'DigitalFarmland',
        component: () => import('@/views/government/DigitalFarmland/index'),
        name: 'DigitalFarmland',
        meta: { title: '数字农田', icon: 'dashboard', affix: true }
      },
      {
        path: 'SmartLnternet',
        component: () => import('@/views/government/SmartLnternet/index'),
        name: 'SmartLnternet',
        meta: { title: '智慧物联', icon: 'dashboard', affix: true }
      },
      {
        path: 'lnputSupervision',
        component: () => import('@/views/government/lnputSupervision/index'),
        name: 'lnputSupervision',
        meta: { title: '投入品监督', icon: 'dashboard', affix: true }
      },
      {
        path: 'PriceQuotes',
        component: () => import('@/views/government/PriceQuotes/index'),
        name: 'PriceQuotes',
        meta: { title: '价格行情', icon: 'dashboard', affix: true }
      }


    ]
  },

]
const router = new VueRouter({
  // mode: "history",
  routes
})

export default router